package main.java.design.chain;

/**
 * <p>
 *     职责链模式
 * </p>
 *
 * @author : wangdejian
 * @version 1.0
 * @date : 2020/6/25 17:42
 */
public class Client {

    public static void main(String[] args) {
        DepartmentManager departmentManager = new DepartmentManager();
        Director director = new Director();
        // 部门经理下一级是总监
        departmentManager.setNext(director);

        departmentManager.handlerRequest("员工张三", 5);

        System.out.println("******************************************");
        director.handlerRequest("员工张三", 10);
    }

}
